
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head>
    <title>秒杀商品详情页</title>
    <%@include file="common/head.jsp"%>
    <%@include file="common/tag.jsp"%>
</head>
<body>
    <div class="container">
        <div class="panel panel-default text-center">
            <div class="panel-heading">
                <h2>${goods.goodsName}</h2></div>
            <div class="panel-body">

                <div class="col-md-12">
                    <table class="table table-bordered">
                        <thead></thead>
                        <tbody>
                        <tr>
                            <td rowspan="6" >
                                <img src="/img/${goods.goodsId}.png"  style="width: 300px;height:300px">
                            </td>

                            <tr><td>库存:${goods.goodsNumber}</td></tr>
                                <tr><td>开始时间:<fmt:formatDate value="${goods.startTime}" pattern="YYYY-MM-dd HH:MM:SS"/></td></tr>
                                <tr><td>结束时间:<fmt:formatDate value="${goods.endTime}" pattern="YYYY-MM-dd HH:MM:SS"/></td></tr>
                                <tr>
                                    <td>
                                        <h2 class="text-warning">
                                        <%--显示time图标--%>
                                        <span class="glyphicon glyphicon-time"></span>
                                        <%--展示倒计时--%>
                                        <span class="glyphicon" id="seckill-box"></span>
                                        </h2>
                                    </td>
                                </tr>
                            </td>
                        </tr>
                        </tbody>
                    </table>

                </div>

            </div>
        </div>
    </div>
</body>

<!-- jQuery文件。务必在bootstrap.min.js 之前引入 -->
<script src="https://cdn.staticfile.org/jquery/2.1.1/jquery.min.js"></script>
<!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
<script src="https://cdn.staticfile.org/twitter-bootstrap/3.3.7/js/bootstrap.min.js"></script>
<%--jquery cookie操作插件--%>
<script src="https://cdn.bootcdn.net/ajax/libs/jquery-cookie/1.4.1/jquery.cookie.min.js"></script>
<%--jQuery countDown倒计时插件--%>
<script src="https://cdn.bootcdn.net/ajax/libs/jquery.countdown/2.1.0/jquery.countdown.min.js"></script>

<script src="/resources/script/seckill.js" type="text/javascript"></script>

<script type="text/javascript">
    $(function () {
        seckill.detail.init({
            goodsId:${goods.goodsId},
            startTime:${goods.startTime.time},
            endTime:${goods.endTime.time},
            userId:"${userId}"
        });
    });
</script>
</html>
